<#macro lookupTree parentId=''>
    <@_categoryList advanced=true parentId=parentId count=500>
        <#list page.list as a>
            <li>
                <#if currentCategoryId?has_content&&a.id?string=currentCategoryId>
                    <a href="javascript:;" onclick="return false;">${a.name!}</a>
                <#else>
                    <a href="javascript:;" onclick="$.bringBack({parentId:'${a.id}',${field!'categoryId'}:'${a.id}', categoryName:'${a.name}'});return false;">${a.name!}</a>
                    <#if a.childIds?has_content>
                        <ul>
                            <@lookupTree a.id/>
                        </ul>
                    </#if>
                </#if>
            </li>
        <#else>
            <li><a><@t.page 'empty_directory'/></a></li>
        </#list>
    </@_categoryList>
</#macro>
<div class="pageFormContent" layoutH="19">
    <ul class="tree treeFolder expand">
        <li>
            <a href="javascript:;" onclick="$.bringBack({${field!'categoryId'}:'',categoryId:'', categoryName:'',parentId:''});return false;"><@t.page 'button.clear_select'/></a>
        </li>
        <@lookupTree/>
    </ul>
</div>